package com.csust.cg.mongodb.domain.vo;

import lombok.Data;

/**
 * @author chenguang
 */
@Data
public class DatabaseVO {

    /**
     * Name of the database.
     */
    private String name;

    /**
     * Number of collections in the database.
     */
    private Integer collections;

    /**
     * Number of views in the database.
     */
    private Integer views;

    /**
     * Number of objects (specifically, documents) in the database across all collections.
     */
    private Integer objects;

    /**
     * Average size of each document in bytes.
     * This is the dataSize divided by the number of documents.
     */
    private Double avgObjSize;

    /**
     * Total size of the uncompressed data held in the database.
     * The dataSize decreases when you remove documents.
     * For databases using the WiredTiger storage engine, dataSize may be larger than storageSize if compression is enabled.
     * The dataSize decreases when documents shrink.
     */
    private Double dataSize;

    /**
     * Sum of the space allocated to all collections in the database for document storage, including free space.
     * The storageSize does not decrease as you remove or shrink documents.
     * This value may be smaller than dataSize for databases using the WiredTiger storage engine with compression enabled.
     */
    private Double storageSize;

    /**
     * Total number of indexes across all collections in the database.
     */
    private Integer indexes;

    /**
     * Sum of the space allocated to all indexes in the database, including free index space.
     */
    private Double indexSize;

    /**
     * Sum of the space allocated for both documents and indexes in all collections in the database.
     * Includes used and free storage space. This is the sum of storageSize and indexSize.
     */
    private Double totalSize;

}
